]> dgit.raspbian.org Git - gnome-shell.git/commit
appDisplay: Fix app folder icon subicon spacing
authorSebastian Keller <skeller@gnome.org>
Wed, 20 Jan 2021 01:03:49 +0000 (02:03 +0100)
committerMarge Bot <marge-bot@gnome.org>
Thu, 21 Jan 2021 21:05:30 +0000 (21:05 +0000)
commit18cd24e6f4d7fe568fb557002d7de05d9fc47a4f
tree7c3aa7aeb77552026b929504fb1790a05533fb03
parent8c792969bb381d7176a59ee75a1dabe42483823b
appDisplay: Fix app folder icon subicon spacing

The code previously was using CSS to define row/column spacing and
padding which was combined with a subicon size computed in code relative
to the requested icon size.

In smaller icon sizes it was possible for the CSS spacing+padding + the
size of the two subicons to exceed the requested icon size. This then
would lead to the label being pushed down for app folders compared to
other icons.

Another more severe issue caused by this would happen if the first item
in an icon grid was an app folder. Then the calculation for the maximum
allowed icon size could be off, leading to all icons in the grid
becoming smaller than actually necessary.

This commit changes this to use homogeneous row and column layouts to
evenly distribute the remaining spacing instead of using a fixed CSS
value.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3069

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1581>
data/theme/gnome-shell-sass/widgets/_app-grid.scss
js/ui/appDisplay.js